﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
using DevExpress.XtraBars;

namespace QuanLyKhachHang
{
    public partial class frmMain2 : DevExpress.XtraBars.Ribbon.RibbonForm
    {
        public frmMain2()
        {
            InitializeComponent();
        }

        private void btnQLKH_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_KhachHang kh = new uc_KhachHang();
            kh.Dock = System.Windows.Forms.DockStyle.Fill;
            kh.Show();
            pnCha.Controls.Add(kh);
        }

        private void btnQLGiaoDich_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_GiaoDich gd = new uc_GiaoDich();
            gd.Dock = System.Windows.Forms.DockStyle.Fill;
            gd.Show();
            pnCha.Controls.Add(gd);
        }

        private void btnQLSP_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_SanPham sp = new uc_SanPham();
            sp.Dock = System.Windows.Forms.DockStyle.Fill;
            sp.Show();
            pnCha.Controls.Add(sp);
        }

        private void btnQLNV_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            UC_QLNV NV = new UC_QLNV() { Dock = System.Windows.Forms.DockStyle.Fill };
            NV.Show();
            pnCha.Controls.Add(NV);
        }

        private void btnQLQuyen_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_Quyen q = new uc_Quyen();
            q.Dock = System.Windows.Forms.DockStyle.Fill;
            q.Show();
            pnCha.Controls.Add(q);
        }

        private void btnQLNhomQuyen_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_NhomQuyen nq = new uc_NhomQuyen();
            nq.Dock = System.Windows.Forms.DockStyle.Fill;
            nq.Show();
            pnCha.Controls.Add(nq);
        }

        private void btnThongTinCaNHan_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            
        }

        private void btnDangXuat_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
        }

        private void barButtonItem1_ItemClick(object sender, ItemClickEventArgs e)
        {
            pnCha.Controls.Clear();
            uc_LoaiSP lsp = new uc_LoaiSP();
            lsp.Dock = System.Windows.Forms.DockStyle.Fill;
            lsp.Show();
            pnCha.Controls.Add(lsp);
        }

        private void frmMain2_Load(object sender, EventArgs e)
        {
            uc_KhachHang kh = new uc_KhachHang();
            kh.Dock = System.Windows.Forms.DockStyle.Fill;
            kh.Show();
            pnCha.Controls.Add(kh);
        }
    }
}